package test;

import java.sql.SQLException;

import javax.sql.DataSource;

import org.apache.commons.dbcp.BasicDataSource;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;
import org.springframework.jdbc.datasource.DriverManagerDataSource;

public class Action1 {
	public static void main(String[] args) throws SQLException {
		ApplicationContext context = new ClassPathXmlApplicationContext("applicationContext1.xml");
//		Render r1 = context.getBean(Render.class);
//		r1.render();
		DataSource dSource = (DataSource) context.getBean("dataSource1");
		System.out.println(dSource.getConnection());
	}
}
